Portable functional electrical stimulation (FES) system for upper or lower extremity applications

ABSTRACT

A functional electrical stimulation system for generating a data file storing stimulation patterns that can be provided to a stimulator is described. The system includes a host computer system for producing a data structure or data file that describes the patterns and a portable stimulator that using the data structure or data file applies electrical pulses to electrodes carried by a patient. The host computer system and the stimulator system each have a memory storing a table having control and pattern generation information with indexes into a table that separately stores electrode characterization data for each electrode used by the portable stimulator.

This appln is a con of Ser. No. 09/184,780 Nov. 2, 1998 U.S. Pat. No.5,983,140 which is a con of Ser. No. 08/870,192 Jun. 6, 1997 U.S. Pat.No. 5,861,017.

BACKGROUND OF THE INVENTION

This invention relates generally to functional electrical stimulationsystems and more particularly to techniques to produce stimulationpatterns for functional electrical stimulation systems usable for lowerand/or upper extremities.

As is known in the art, research in upper and lower extremity functionalelectrical systems has been ongoing for a number of years. Functionalelectrical stimulation uses an electronic system to generate electricalpulses that are delivered to muscles o a patient who has muscle movementimpairment. The muscle movement impairment is due to some condition thatcauses muscle paralysis. This condition can be nerve damage c used byaccident or disease. The functional electrical stimulation systemproduces electrical signals that can be used by the patient to controlmuscle movement.

Practical electrical stimulation systems require a stimulation systemthat is small, lightweight and portable. Such a system would to allow asubject patient to operate the system to learn to perform everydayactivities. On the other hand a practical system requires sufficientversatility and power to enable practical utilization of generatedelectrical stimulation patterns to produce a variety of musclemovements.

Several portable systems have been described in the literature. As isknown, one of the problems common to these systems is the approach usedto generate the electrical signal patterns. The described systems areeither built for upper or lower extremity movement but not both oreither. In general, the known systems cannot handle different types ofsensors. Thus, systems are designed for a particular type of sensorassociated with the desired type of stimulation. Further, the approachesused to process inputs to produce stimulation waveform generally are notsufficiently robust to accommodate different sensors.

Different sensors and algorithms are necessary for each type ofstimulation because the characteristics of the upper and lower extremitymovements are different. Lower extremity movements can be characterizedas repetitive, predictable movements, whereas upper extremity movementsare more spontaneous in character. A second problem is that forpractical, useful movements of muscles generally several muscles must beoperates in unison or concert to produce the practical movement. Thus,in addition to providing an algorithm which allows for relatively easygeneration of such produced muscle movements, it is also desirable toprovide an overall system that can be adapted for upper or lowerextremity stimulation or both.

SUMMARY OF THE INVENTION

In accordance with the present invention, a memory containing a datafile having da a that under control of a program executed by a functional electrical stimulator (FES) system produces at least one functionalelectrical stimulation pattern. The pattern under control of the programprovides signals that ire coupled to electrodes used by the functionalelectric al stimulator. The data file includes a table storing controland pattern generation information and separately storing electrodeactivation data for each electrode used by the portable stimulator. Withsuch an arrangement, by storing characterization data separately frompattern data, it allows the Stimulation Pattern to be unaffected by achange in electrode characteristics, since to compensate only requires achange in the parameters of the electrode. It also allows generalizedPattern templates to be produced with most of the user specificinformation generated directly from Profiling sessions with a patient.This provides a unified approach to producing electrical signal patternswhich takes into consideration the various complexities involved incontrolling muscles.

In accordance with a further aspect of the present invention, a methodof generating stimulation patterns for execution by a functionalelectrical stimulator system includes the steps of forming a pluralityof primitive movement patterns by electrical y stimulating selectedelectrodes contacting a subject patient and choosing for each one ofsaid plurality of primitive movement patterns one or more of saidselected electrodes to produce the primitive movement. The methodcombines from the plurality of primitive movements at least one or moreof the primitive movements to produce an interval pattern for each oneof a plurality of desired interval movement and combines at least one ormore of said interval movements to form a complex movement controllableby a user. With such an arrangement, a hierarchical approach to formingcomplex movements is provided. This insulates the Stimulation Patternfrom the specifics of the individual electrodes profiling informationand location. Thus all patterns are generated through combining ofprimitive movements, which are logical mappings of a desired effect(movement) to the physical stimulation required to obtain that effect,as determined during electrode profiling sessions. This allows thepattern to be unaffected by a change in electrode characteristics, sinceto compensate requires only a change in the parameters of the primitivemovements. It also allows generalized Pattern templates to be producedwith most of the user specific information generated directly from theProfiling session.

BRIEF DESCRIPTION OF THE DRAWINGS

The foregoing features of this invention will now be described inconjunction with the accompanying drawings, in which:

FIGS. 1A and 1B are pictorial representations of a functional electricalstimulation n system for upper body extremities (FIG. 1A) and lower bodyextremities (FIG. 1B).

FIG. 2 is a block diagram representation of a host computer and aportable stimulator used in the functional electrical stimulation systemof FIG. 1;

FIG. 3 is a schematic diagram of a signal processor module used toproduce stimulation signals for the portable stimulator shown in FIG. 2;

FIG. 4 is a flow chart showing the major steps required in generating amovement pattern at the user level;

FIG. 5 is a flow chart of a technique to form primitive movements; and

FIGS. 6A-6C are diagrams of a representative data file or data structureshowing data tables used in the stimulator;

FIG. 7 is a flow chart showing steps in using the dat structure of FIGS.6A-6C to produce stimulation signals; and

FIGS. 8A to 8D are flow charts showing steps used in generatingstimulation patterns.

DESCRIPTION OF THE PREFERRED EMBODIMENT

Referring now to FIGS. 1A and 1B, major system components of thefunctional electrical stimulation system 10 are shown pictoriallyinterconnected to the upper and lower extremities of a human patient. Inparticular, the functional electrical stimulation system 10 includes ahost computer 12 which executes software to generate movement patterns,as will be further described in conjunction with FIGS. 3-6. In additionto the software, the host computer 12 also stores data files which areused to provide stimulation patterns. These da a files are fed to aportable stimulator unit 14. In response the portable stimulator unit 14produces electrical signals which are coupled to the muscles of thesubject patient 20 via cables 16. The cables 16 couple the stimulator tointramuscular electrodes 18 disposed on the patient upper limbs (FIG.1A) or lower limbs (FIG. 1B). Any suitable type of muscular electrodesmay be used. For example, the muscular electrodes may be of thepercutaneous intramuscular electrode type which are electrodes that areimplanted with a minimally invasive needle insertion procedure, as wellas fully implanted electrodes or surface electrodes. Cables 16 a areshown coupling various sensors (not numbered) on the human patient tothe stimulator 14.

In accordance with the particular electrode type used, the stimulatorunit 14 will have its circuitry adapted to suitably drive the selectedelectrodes. The electrodes are implanted at various locations long thelimbs as shown in FIGS. 1A and 1B in a manner which would be apparent toone of skill in the art.

The stimulator unit here al so includes a portable battery pack and anoutlet for a battery charger which is used to charge the battery pack

In general there are two modes of operation for the functionalelectrical stimulation system 10. In the first mode of operation, acharacterization and generation mode of operation, the host computer 10under control of a trained operator will characterize the overall systemin conjunction with a particular subject patient 20 to producestimulation patterns for electrical signal generation. These stimulationpatterns are stored as data files in the host computer system 12. Afteradequate generation of all stimulation patterns the data files aredownloaded to the stimulator unit 14. Within the stimulator unit, thesecond, stand-alone mode of operation occurs. That is, under patientcontrol the subject patient 20 can select patterns via various userinterfaces to enable movement of muscles in the subject patient.

Referring now to FIG. 2, the functional electrical stimulation system isshown to include the host computer 12, here a PC-based computeroperating under a Windows NT operating system. Other computer platformscould alternatively be used. The host has a serial port 12 a whichcouples to a corresponding serial port 14 a in the portable stimulator14. The host computer 12 includes a software program 13 a which is usedto develop stimulation is patterns. The host download files 13 bcorresponding to the developed stimulation patterns to the portablestimulation unit 14. An example of a pattern stimulation file 13 b willbe described in conjunction with FIGS. 6A-6C. The stimulation patternprogram comprises three portions, an electrode characterization portion,a movement development portion and a pattern generation portion. Thestimulation pattern generation program 13 will be further described inconjunction with FIGS. 3-6.

The portable stimulator 14 includes an off-the-shelf single boardpersonal computer board 31 here comprised of an eight bit CPU 32, randomaccess memory 34, a solid state disc 36, the serial port 14 a mentionedpreviously and a parallel port 38. The random access memory 34 is usedto execute programs to produce or generate patterns for the portablestimulator; whereas, the solid state disc 36 is used to store theprograms 36 a and store the pattern generation files 36 b. The parallelport 38 is used to produce electrical signals which are fed throughstimulation circuitry and used to produce the electrical signals whichare coupled to electrodes in the subject patient. In addition to theaforementioned single board personal computer 31, the portablestimulator includes an I/O module which is coupled to the centralprocessor 32 via a PC bus 31. PC bus 31 is also used to couple the RAMand solid state disc to the computer 32. The I/O module 39 includesprovisions for analog and digital inputs as well as analog and digitaloutputs and is used to couple signals on a signal processor module 50 tothe processor 31.

The signal processor module 50 includes the sensor circuits used tointerface Hall effect transducer devices and force sensing resistors tothe portable stimulator 14. The Hall-effect transducers are positiontransducer devices disposed on the subject patent and are used tomeasure joint angle for proportional control of stimulated movement. Theforce sensing resistors are commercially available thin film sensorshaving resistance changes proportional to changes in applied force. Theforce sensing resistors are inserted into shoes of the subject patientand are used to sense foot to floor contact during stepping. The forcesensors provide reference triggers for enabling or disablingstimulation. The module 50 in addition includes stimulation circuitry 52that produces in response to signals fed from the parallel port 38electrical signals that are fed along the cable 16 to the subjectpatient. The stimulation circuitry 52 is particularly adapted ortailored for the particular electrodes which are used on the subjectpatient. An example of the stimulation circuitry 52 is shown in FIG. 3for percutaneous electrodes.

Referring now to FIG. 3, the signal processor circuit 50 is shown toinclude a channel selector 60 comprised of three 8 channel analogmultiplexers 60 a to 60 c and a digital decoder 61. Signals STIMCH3 andSTIMCH4, PLSTIM and CHIP ENABLE are fed to the digital decoder 61 andproduce as an output thereof one of three digital signals (correspondingstates to 0,1 or 2 ) which act as enables to one of the three analogmultiplexers 60 a-60 c as shown. The analog multiplexers receive asinputs, signals STIMCH0-STIMCH2 which are used to select one of eightchannels in each one of said multiplexers. Signals STIMCH0-STIMCH2 andthe signals from decoder 61 enable one of here twenty-four possibleoutputs. Thus, with PLSTIM LOW the desired channel is selected bysignals TIMCH0-STIMCH2 and the selected enable signal from decoder 61.

For the desired channel selected in accordance with said signals, thesignal ISET coupled to one of the 24 output channels. The signal ISEThas a voltage corresponding to a desired waveform pattern. The voltageis provided from a D/A converter (FIG. 2 ). It is applied to the base ofthe corresponding output transistor Q1-Q24. As long as this voltage isabove the base voltage of the corresponding transistor Q1 to C24, here0.85 volts, the corresponding transistor is turned on causing theassociated one of the capacitors C1 to C24 at the output stage of eachone of the said transistors Q1 to Q24 to discharge. The stimulationcurrent is then produced and can be calculated by the following equationbased on the voltage level IST:

I _(simulation)=((IST−V _(BE))/R _(g))−0.5

where RE is a 180 ohm emitter resistor. When PLSTIM returns to a higherlevel, the corresponding transistor in the channel is turned off sincethe base is pulled down by a 100 Kohm resistor. The correspondingstimulation capacitor C1 to C24 is then recharged at a rate not greaterthan 0.5 milliamps as limited b the diodes D1-D48 in the collectorcircuit of the transistor.

The signal processor circuit 50 in addition includes three circuitswhich are used to monitor the stimulation status. An operationalamplifier 71 a is used to sense the pulse which occurs in the select edone of the channels CH1-CH24 and is used as an input to the pulsedetection 72, short capacitor detection 73 and pulse sense circuits 75.The operational amplifier 71 a amplifies the pulse signal at node VSNSby a value corresponding to the gain of the amplifier 71 a, here −100.If the amplified output value of the voltage VSNS is greater than VBE ofthe transistor 71 c, then the base of the transistor kill turn ontriggering the D-Flip Flop 72 a causing the pulse being sent signal “PD”to assert. This signal is fed to the CPU in the stimulator 14 toindicate that the pulse was in fact,sent. The signal PDRESET providedfrom the CPU In response to PD resets the flip flop 72 a and causessignal PD to deassert in anticipation of the next stimulation pulse. Aresistor R1 and capacitance C1 are disposes to provide a low pass filter69 between VSNS and ground. The lowpass filter 69 prevents detection oflow duration or low level signals.

A shorted capacitor condition circuit 73 detects a constant current flowthrough the resistor R1 when there is no stimulation pulse. Thus, thepotential at VSNS is also used to detect a shorted capacitance that isproportional to the current. For this circuit, the voltage is amplifiedin two stages. The first stage corresponds to stage 71 a and the secondstage correspond to a second operational amplifier stage 73 a. If thepotential at VSNS is greater than the base emitter voltage a thetransistor 73 b, the transistor will turn on causing SD to go low. Thiscondition occurs if the leakage current is greater than 0.02 milliamps.

The third circuit 75 is a circuit used to measure the output pulse. Thesignal ISTIM (stimulator current) is a buffered reading of RE_OUT tocheck if the programmed current matches the actual current. The value ofISTIM is only meaningful during stimulation. It is fed to an A/Dconverter and digitized to produce a digital signal which can becompared against the corresponding digital signal used to produce ISTIMvoltage level.

Referring now to FIG. 4, a process 100 used to generate movementpatterns for a subject patient is shown. The process 100 is executed inthe host system 12 under control of a trained operator.

At a first or initial level the host computer system 12 is used tocharacterize each i individual electrode response 110 a to 110 i throughelectrode profiling. Electrode profiling provides a technique todescribe the electrical parameters needed to stimulate a given electrodeto produce a desired muscular response. Each electrode in every patientis profiled for this purpose. Each electrode is assigned a unique numberused for identification. This number is mapped to the channel to whichthe electrode is connected. This allows the electrode's characteristicsto be portable and not associated with any specific channel Theelectrode is profiled to provide the information needed to accuratelydescribe its characteristics.

The first step in profiling an electrode is to select an appropriateamplitude and frequency (NOTE: When these parameters are adjusted, theprofile information is reset. Also these will be the default parametersfor the given electrode). Once appropriate parameters are established,the affected muscles can be determined. Up to three muscle/movementpairs can be recorded with the following information:

0% Threshold pulse duration 100% Saturation pulse duration Force/ Scaledfrom 0 (no response) to 5 Strength of (Normal) (Manual Muscle TestScale) Muscle Length Scaled from 0 (non-functional) to 2 Dependency(Functional)

A history of the information is recorded as the electrode is profiledmore than once to allow the operator to use the information from a pastprofiling session if necessary. The values of frequency and amplitudeare stored in tables IPI and Current, as will be described inconjunction with FIG. 6.

It is generally necessary to characterize the electrode responses foreach implant electrode to determine whether or not multiple electrodesare required to generate a particular muscle movement. Often withpercutaneous electrodes multiple electrodes are required to generatesufficient force to produce sufficient muscle movement. The forcegenerated by the muscle is dependent upon several variables including,most notably, electrode position. The technique of needle insertion ofpercutaneous intramuscular electrodes is a somewhat inexact science.Often more than one electrode is necessary to generate sufficient forceto produce sufficient movement of the muscle.

After each of the characteristics of the electrodes have beenascertained, primitive movements are developed. Desired, primitivemovements are selected and generated as a result of the combination ofone or more electrodes needed to provide a desired motion. This is aniterative process in which electrical stimulus is provided to one or agroup of electrodes and the reaction, i.e., physical movement of themuscle in the subject patient is observed and recorded in the hostcomputer. In this manner the requisite number of electrodes and weightsfor each of the selected electrodes are determined. Thus, as shown inFIG. 4, for the thumb extension movement 120 a M1, two individualelectrode responses from electrodes 110 a and 110 b are weighted andcombined to produce the required electrical stimulation for the desiredthumb extension movement. Similarly, for each one of the other movements120 b-120 f different combinations of electrodes and weights areselected and assigned to the electrodes. Thus, finger extension movement120 c is provided by weighting responses of electrodes 110 c and 110 dand so forth.

Referring now to FIG. 5, an electrode to primitive movement mappingtechnique is shown. To insulate the Stimulation Pattern from thespecifics of the individual electrodes profiling information andlocation, all patterns operate through primitive movements, which arelogical mappings of a desired effect (movement) to the physicalstimulation required to obtain that effect, as determined duringElectrode Profiling sessions. This layer of abstraction allows thePattern to be unaffected by a change in electrode characteristics, sinceto compensate requires only a change in the parameters of the PrimitiveMovements. It also allows generalized Pattern templates to be producedwith most of the user specific information generated directly from theProfiling session.

A Primitive Movement is assigned a unique name (step 210 ) generallydescriptive of it function. Each Primitive Movement can specify up tothree desired movements, in order or priority, as its Primary, Secondaryand Tertiary movement. This will provide a list of electrodes thatproduce the specified movements (step 220 ). These electrodes aresorted, from “best” to “worst”, according to their appropriateness forthe g given movements selected, based on the Electrode Profiling. Thepurpose of identifying primary, secondary end tertiary movements is thatcertain muscles can produce several movements from a single stimulationbecause the muscle crosses one or more joints in the body. For certaincomplex movements, the secondary and/or tertiary movements can bebeneficial and thus used in generating the movement. For other complexmovements, the secondary and tertiary movements hinder the desiredcomplex movement. With the latter case, an attempt is made to compensatefor these secondary and tertiary movements.

Therefore, any combination of some or all of the resulting electrodesmay be used with the default being that only the “best” electrode isenabled and all others are disabled (step 240 ). Each electrode can havespecified the Minimum and Maximum, artificial clipping limits thatspecify the range that the user is permitted to adjust the pulseduration in. These values default to the 0% (Minimum) and 100% (Maximum)of the Primary Primitive Movement of the electrode.

Because with percutaneous intramuscular stimulation it is common to useseveral electrodes in combination in order to generate a singularstimulation movement, for example, a knee extension or a finger flexure,a movement development window is designed to effectively determine thecombined effects of several electrodes before combining differentmovements. The user can select primary, secondary and tertiary movementsfrom a database of muscles and associated movements. Based on theselection, the computer chooses the best electrodes using a weightedcombination of the muscle force and length dependency scores determinedduring electrode characterization. The operator can activate the chosenelectrodes simultaneously to observe the combined effects. In order tohave a consistent interface between Patterns and Primitive Movements,all Patterns refer to the Primitive Movement as having a value between 0and 100 inclusively (NOTE: A value of 0 corresponds to a pulse durationof 0, no stimulation, for all electrodes) (step 260). These values aremapped to electrode pulse durations. The default mapping of Indexes topulse durations is a ramp function from the 0% to the 100% of thePrimary Movement. The starting point and end point of the ramp can bemodified to any value in the range specified by the Maximum and Minimum.

Since the response of many electrodes is nonlinear with pulse duration,a mechanism (step 270 ) to allow a piece-wise linear mapping isprovided. Up to 6 sub-ramps are permitted per electrode allowing avariety of waveform shapes. These sub-ramps can begin n and end at anyindex and specify any pulse duration within the acceptable range. Thispiece-wise mapping of Movement Indexes to multiple electrode pulsedurations allows the Movements to perform complex functions, if sodesired The movement is tested until the desired electrode combinationand pulse width mapping is achieved.

After suitable movements have been achieved, a three step hierarchialapproach is used to combine the Primitive Movements to enable morecomplex control of muscles and to enable move complex operations.Stimulation patterns are generated in a hierarchical configuration,broken down into three separate levels. These are, from lowestcomplexity to highest, Intervals, Stages, and Patterns. By using such anapproach, it is possible to develop a database of movements and tocombine Primitive Movements in the database in different combinations toachieve new complex movement patterns. This can be achieved rathereconomically since all the initial characterization of the PrimitiveMovements is already performed. Thus, it is merely necessary to combinethe primitive movements to achieve the more complex movements.

The first level of the hierarchical process is the interval level. Atthis level, intervals are developed which include a combination ofmovements as shown at 140. Thus, for example, the interval “graspextension” is a combination of a “thumb extension” movement 120 a and a“finger extensions” movement 120 b. Defined within the interval is, inaddition to the movements is the type of control to be used; that is,whether the control is a time based control or a proportional basedcontrol. Further, the duration of the time interval or a proportionalsignal based on the control selected are also determined. In addition,any break points or branching points to alter, stop or hold stimulationmovement are selected. Branching conditions include reaching a thresholdlevel of the force sensor resistors or a threshold level of theHall-effect transducers, hitting a button on a thumb switch unit or aloop option to automatically repeat the interval.

Intervals provide the lowest level of control, containing theinformation for stimulation, user notification, and branchingconditions. This information is stored in the following tables: Tics andbreakpoint. The Tic contains the basic information for stimulation. Thecontents of the Tic table describe pulse-shape parameters. The Tic tablecontains, for each channel, the Pulse Duration (0-255 uS.), the InterPulse Interval (IPI, 1-1023 mS.), and the Amplitude ( 0.0-20.0 mA.).Also in the Tic is the information about how long to star at the Tic andwhat action, if any, to take during the Tic (see Breakpoint).

There are currently two methods of controlling stimulation; Timed andProportional control. Each of these two types requires the sameinformation in the other fields, however, the information is interpreteddifferently. The difference between the two control methods is thedefault destination when the Tic is completed. In Timed control, the Ticsimply proceeds to the next Tic. In Proportional control the next Tic isdetermined by a Control Signal. An external signal ranging from 0 to 100is mapped to a value between 0 and 399 and used to index the next Tic.The external signal is generated from the Hall Effect sensors or fromthe force reaction of another muscle. The duration of the intervalspecifies the overall length that the interval takes to execute. ForTimed Intervals, this is a value in mS which also determines the numberof Tics in the Interval. For Proportional Intervals, this value isbetween 1 and 100 and determines the percent of the command range thatthis interval occupies. The Breakpoint contains the information thatdetermines the user notification and the branching condition. The usernotification is a message displayed on the LCD of up to 9 characters, aprogrammable Beep Pattern, and a programmable blink pattern on theThumbswitch LEDs. The branching condition can be one of the following:

GO button met when the GO button is depressed during the Breakpoint FSRtrigger pattern met when any logical combination of above or belowprogrammed thresholds Hall effect met when normalized velocity meetsspecified conditions Loop #N times met first #N times, then not met alltimes after that

The branching condition can be triggered at any time during theinterval. For a Timed Interval, the Breakpoint is valid during the firstTic of the Interval, which can be of a programmable duration. ForProportional Interval, the Breakpoint can be valid for any desiredpercentage of the first part of the entire Interval. The option existsin the Breakpoint to disable the ability to have an emergency exit.

As shown in FIG. 4, at the next level a stage 150 is developed whichcombines a group of intervals to produce a more complex movement. Thestage level integrates control and generation information for theselected intervals. A Stage can contain only Intervals with the samecontrol type, either proportional or timed. A Stage also controls thebranching from one Interval to the next. When the Breakpoint of anInterval is completed, depending on the exiting condition, the Stage canbranch to either another Interval in the Stage or to a specialdestination. The exiting conditions of the Breakpoint can be one of thefollowing three:

Default Occurs when wait time has expired and no other condition met.(Not valid for PC) Event Occurs when the Breakpoint condition is metExit Occurs when the Exit condition (EXIT Button) is met

Each of these conditions can have their own destination of any Intervalin the Stage or one of the following special destinations:

Continue Continues to the next Tic (Timed only) Stage Next Goes todestination specified by Pattern Stage Branch Goes to destinationspecified by Pattern Stage Exit Goes to destination specified by PatternNext Interval Goes to the next Interval in the Stage Previous IntervalGoes to the previous Interval in the Stage Stim Unlock Unlocks Stim

For example, as shown in FIG. 4, the “grasp extension” interval 140 acan be combined with the “grasp flexion” interval 140 b to produce alateral grasp and release movement 150 a. A stage controls both theinterval sequence as well as branching conditions between intervals.

The next level in the hierarchy is the Pattern. At the highest level,one or more stages are brought together to represent a pattern as shownin level 160. This is the level at which the user chooses and controlsstimulation movements. For example, a pattern can be several stages suchas lateral pinch and elbow extension or standing and side-stepping. ThePattern is similar in structure to the Stage. A Pattern contains a groupof Stages and the branching relationship between them. The Branchingconditions can be one of the following three:

Next Occurs when Stage Next destination occurs in Stage Branch Occurswhen Stage Branch destination occurs in Stage Exit Occurs when StageExit destination occurs in Stage

The destination of each of the conditions can be any of the Stages inthe Pattern or one of the following Special Destinations:

Menu-Stim On Returns to the Menu leaving Stim On Menu-Stim Off Returnsto the Menu turning Stim Off Next Stage Goes to the next Stage in thePattern Previous Stage Goes to the previous Stage in the Pattern

Once a stimulation pattern is designed, the program produces asimulation parameter table (as will be described in FIGS. 6A to 6C) thatcontains all the information necessary for the stimulator to execute thepattern. The stimulation pattern table is downloaded to the solid statedisc 36 (stored as file 36 b) in the stimulation unit 14 via the serialinterface. Typically several patterns for functional use and stimulationexercise are developed and transferred to the stimulator 14. Patternchoices are displayed on an LCD and chosen via thumb switches or Halleffect transducers as appropriate for the pattern and the patient.

The program resident in the stimulator executes a stimulation patternretrieved from a stimulation parameter table in accordance with thatdesired by the thumbswitches or the Hall effect sensors. The program inthe stimulator schedules and executes stimulation pulses for eachchannel, samples and processes control signal data and performs usernotification via the LED display on the Thumbswitch, the LCD display andaudio tones. On command from the stimulation parameter table, theprogram will also store data such as the control signal system mode,time and data views and pattern used in approximately 1 megabyte ofunused solid storage disk space.

Once the patterns have been produced, Menus can be produced to controlwhich Patterns and functions are accessible to the user of thestimulator. Menus can be controlled either with the Thumbswitch or bythe Hall Effect Transducer. Three different kinds of menu items can beadded to each Menu:

Menu Other Menus (Sub-Menus) Patterns User programmed Patterns FunctionsPredefined functions and procedures

Upon system power up, the Menu Main Menu will become active, so anydesired Menu, Pattern or Function must either be in this Menu or in oneof the Menu Branches originating in Main Menu.

Referring now to FIGS. 6A-6C, an illustrative pattern stimulation file13 b produced by the host system 12 for use in the portable stimulatorsystem 14 is shown to include a header file 302. The header file 302contains general information concerning the configuration of the systemand the patient who is using the system. After the header file are oneor more menu tables 304. Each of the menu tables contains all of theinformation for a menu system which allows a user to navigate throughthe system and perform desired tasks. Each menu allows the user toselect one of several possible Destinations. In addition to Destinationinformation, the menu also contains information regarding how the menuis navigated, that is, by Thumbswitch or Hall Effect Transducer. EachDestination allows a user to select one of several possible options. TheDestination contains information on the type of destination, currentmenu, pattern and function, as well as an index into a table for each ofthe types.

The next table is a pattern table 306 which contains a list of all userselectable patterns. Each user selectable pattern 306 a-306 i contains afield corresponding to the name of the pattern and an index into aBreakpoint table which provides the starting point for the pattern.

The Breakpoint table 308 contains a listing of all of the Breakpoints.Each Breakpoint contains several fields which provide specialinformation used during stimulation to control the flow of the Pattern.Each Breakpoint includes a notification field which contains a<message>which is used to produce user feedback through the visualdisplay and LED as well as auditory beep sounds. The next field is a Ticindex which contains an index into Tic tables. The Tic table 310determines the stimulation levels. The next field is an event fieldwhich contains information which permits the system to handle a specialevent. The types of events supported include operations triggered byassertion of a GO button, force sensing resistors (FSR), Hall EffectTransducers and a LOOP option. Since there are in general more than onecondition for each of the types, an index into the desired type is alsoprovided. If a special event occurs, then the Pattern branches to theevent Breakpoint index specified in the table.

If no event is desired or if an event does not occur then the controltype specifies the type of control to be performed on the pattern. Twotypes of control are provided, time control and proportional control andare specified in control field. The control type also specifies theDestination that the CPU will go to after the control operation isexecuted. The next field in the Breakpoint table is an EXIT conditionfield which is used to handle emergency condition such, for example, ifthe user presses the EXIT button. This field contains the EXITBreakpoint index which will control where the patterned branches shouldbe.

The next table in the file 300 is the Tic table 310. The Tic tablecontains data used to provide pulse shapes and duration for thestimulation pulses. The Tic table contains a list of all Tics,inter-pulse intervals and current amplitude tables. The Tics contain theinformation required for stimulation. This information includes thepulse duration in microseconds stored in field 311 a for each channel,an index into the IPI table in field 311 b and an index into the currenttables in field 311 c. The IPI table 312 and current amplitude tables314 as shown contain respectively the inter-pulsed interval inmilliseconds for each of the channels and the current table contains acurrent level or amplitude for each of the channels. These tables arepopulated independently of the pattern generation process. They arepopulated during the electrode characterization process and thus permitchanges in electrode characterization to have a minimal effect onpattern generation. The IPI table 312 and the current table 314 areshown having an index corresponding to channel number and a valueassociated with the index.

As shown in FIG. 6C, the file further includes force sensing resistorcondition table 320, Hall Effect condition table 322, Hall Effectthreshold Table, 324, Loop tables 326, Beep table 330 and LED table 334.

For each force sensing resistor, the FSR table contain fieldscorresponding to left condition, right condition, FSR logic and athreshold index. The FSR Condition Table contains a list of all of theFSR Conditions and FSR Thresholds. FSR Condition fields containinformation to describe a Breakpoint Event condition for the FSRs which,if met, triggers the branch in the Breakpoint. The Left Condition fieldcontains a Truth Table for the four FSRs on the Left foot. This allowsthe result for any combination of On/Off (a total of 16 possibilities)to result in a triggering condition. The Right Condition field containedthe Truth Table for the four FSRs on the Right foot. This allows theresult for any combination of On/Off (a total of 16 possibilities) toresult in a triggering condition. The FSR Logic field indicates whatcombination of the Left and Right Conditions will result in thetriggering being met. These conditions include:

Left Only

Right Only

Left And Right

Left Or Right

The Threshold Index field contains an index into the FSR Threshold Tabledescribing which table of Thresholds is to be used for the FSRs to beconsidered On or Off. The FSR Threshold Table contains an array ofThresholds for each of the FSRs, above which the FSR is considered On,below which the FSR is considered Off.

For the HALL Effect condition table 322, each Hall condition contains afield corresponding to range and a field corresponding to velocity. TheHall Condition Table contains a list of all of the Hall Conditions andHall Thresholds. The Hall Condition field contains information todescribe a Breakpoint Event condition for the Hall Effect sensor which,if met, triggers the branch in the Breakpoint. The Range field describesa minimum distance the Hall Effect sensor must travel in a specifiedamount of time in order for the Hall Condition to be met. In theVelocity field, if the Range condition is met, then the Velocity of theHall Effect sensor must be above this value and also below a fixedlimit. If these three conditions are true, then the triggering conditionis met. The Hall Threshold table 324 specifies the number of levels ofthe Hall Effect sensor's range. This is currently used to controlaccessing Menus and for Proportional Control Indexing.

The Loop table 326 contains a stored value for each Loop countcondition. The Loop Table contains information to describe a BreakpointEvent condition to branch to the same Breakpoint a specified number oftimes. The Loop Count indicates the number of times to repeat theBreakpoint branch. The triggering condition is met for Loop Count times,then it is not met again. Similarly, the Beep table and the LED tableshave stored values for each Beep pattern and LED pattern, respectively.The LED Table contains an array of LED Patterns. These are accessed bythe Breakpoint Notification field. The LED Pattern describes a blinkingpattern for the LEDs and contains the information to describe an On/Offpattern, the frequency of switching, and the total duration of thepattern. The Beep Table contains an array of Beep Patterns. These areaccessed by the Breakpoint Notification field. The Beep Patterndescribes a beeping pattern for the Beeper and contains the informationto describe an On/Off pattern, the frequency of switching, and the totalduration of the pattern.

Functions are not contained in the pattern stimulation file 13 b. Thefunctions are predefined and built into the program. The Destinationfield is a way of accessing these Functions.

Referring now to FIG. 7, the major routines in a software program 400executed on the portable stimulator 14 are shown. The program 400includes a menu processing program 410 which responsive to inputs fromuser control devices provides menu screens (not shown) to enable theuser to step through the various features of the portable stimulator 14.The menu program also provides a pattern index to a pattern generationprogram 420 in accordance with a pattern selected by the user.

Therefore, the software program 400 also includes the pattern generationprogram 420 (which will be further described in conjunction with FIGS.8A and 8B. The pattern generation program produces the stimulationsignals on the electrodes 18 coupled to the subject patient inaccordance with inputs provided by sensors disposed on the patient. Thesoftware program 400 also includes Hall Effect processing program 430,force sensing resistors (FSR) program 440, Thumbswitch program 450 andloop program 460. These programs process inputs to the menu program 410for display in the menu and the pattern generation program 420 tocontrol generation of stimulation patterns.

The software program also includes an LED, beep program 470 which isused to control in conjunction with the menu program 410 visual/audiomessages to the user.

Referring now to FIGS. 8A-8D, the pattern generation program 420 whichis executed in the stimulator 14 is shown to include step 510 which isused to access a particular stimulation pattern in the pattern table 306(FIG. 6A). The pattern table is indexed via the pattern index providedfrom the menu program 410 (FIG. 7). In step 512, the name of the patternis displayed (via processing by the menu program and LED/beep program).At step 514, the program 420 accesses the Breakpoint table by the indexprovided from the pattern table.

Referring now in particular to FIG. 8B, the pattern generation program420 uses information in the Breakpoint table as follows:

In response to setting a breakpoint at step 515, the software retrievesthe active breakpoint at step 517 and sets the Tic index at step 519.The Tic index is used to index into the Tic table using the Tic routine540 as will be described in conjunction with FIG. 8C. The Breakpoint isalso used to set the control index at step 521 which will use the timerroutine 560 (FIG. 8D). The Breakpoint routine displays messages in theBreakpoint table at the Breakpoint index at step 523. At this point ifan event is indicated at step 525, the software will branch to check ifa breakpoint has been set at step 527 with new data provided from steps510 and 512 as shown. Thereafter, it will exit at step 529 and return tothe menu at step 530. If a new breakpoint was not set, however, controlwill transfer back to step 515. Step 525 will remain in an idle stateuntil an event occurs that transfers control to step 527.

Referring now to FIG. 8C, the Tic routine is shown to include a stepthat fetches the active Tic routine as indicated by the Tic index atstep 542. The routine checks to see if the Breakpoint is set or clearedat step 544 and will branch to the Breakpoint routine 514 if theBreakpoint is set, or if the Breakpoint is clear it will continueprocessing through the next step 546. At step 546, the timer routine 560(FIG. 8D) is entered. When the timer routine returns back to the Ticroutine, the Tic routine will access the IPI table at step 548 andaccess the current table at step 550. At step 552 it will continue toprovide stimulation pulses until the Breakpoint in step 544 is set.

Referring now to FIG. 8D, the timer routine 560 is shown. Timer routine560 is entered in response to a set time condition or a set controlcondition. At step 562 a time value is initialized. At step 564 a timervalue is incremented by an amount determined by step 566 and at step 565the timer value is checked to see whether a preset time value has beenreached. If a time value has not been reached, the time value isincremented at step 564 by the value supplied at step 566. If the timevalue has been reached at step 567, the control type from the controlfield in the breakpoint table 308 (FIG. 6B) is checked to determinewhether it is a time control or a proportional control. If it is timecontrol, processing continues at step 569 in which the breakpoint ischecked. If the breakpoint has been set at step 571, the breakpoint isset to the next breakpoint and processing continues in the breakpointroutine. If the breakpoint is not set, then processing continues at 570to set the Tic to the next Tic and continue processing in the Ticroutine 540.

If, however, the control type is determined at step t 67 to beproportional control, then the control signal specified for theparticular operation is obtained and the Tic is set for the particularcontrol signal at step 574. Processing then continues in the Tic routineat step 540 in accordance with the value of the control signal.

Having described preferred embodiments of the invention, it should benoted that other embodiments incorporating its concept may be used. Itis felt, therefore, that this invention should not be limited to thedisclosed embodiments, but rather should be limited only by the spiritand scope of the appended claims.

What is claimed is:
 1. A method of generating stimulation patterns forexecution by a functionalelectrical stimulator system comprises:accessing a particular stimulation pattern in a pattern table, withpattern table indexed by a pattern index; and accessing a Breakpointtable by the index provided from the pattern table.
 2. The method ofclaim 1 wherein accessing a Breakpoint table further comprises: usinginformation in the Breakpoint table to set a breakpoint, and to set aTic index to index into a Tic table using a Tic routine.
 3. The methodof claim 1 wherein the pattern table includes a listing of a pluralityof stimulation patterns, including a field identifying the pattern and afield containing a BreakPoint index to the accessed BreakPoint table. 4.The method of claim 1 wherein the BreakPoint table further includes anevent field storing an index to an event routine and a control fieldstoring a value that determines whether control is time based orproportional based.
 5. The method of claim 1 wherein the table storescontrol and pattern information.
 6. The method of claim 5 wherein thetable storing the control and pattern information further comprises amenu table storing information to enable a patient to access stimulationpatterns.
 7. A functional electrical stimulator, comprises: a processorexecuting a program which provides from a stimulation pattern file adigital signal: a memory storing said stimulation pattern file, saidstimulation pattern file comprising: a table storing control and patterngeneration information and separately storing electrode characterizationdata for each electrode used by the portable stimulator, a signalprocessing circuit responsive to the digital signal for generatingelectrical stimulation pulses and coupling said pulses to electrodesused by the portable stimulator; wherein the stimulator unit operates instand-alone mode that is permits a subject patient to select patternsvia user interfaces to enable movement of muscles in the subjectpatient.
 8. The functional electrical stimulator of claim 7 furthercomprises: a simulation parameter table that contains information toexecute a stimulation pattern, the stimulation pattern table beingdownloaded to a device in the stimulation unit.
 9. The functionalelectrical stimulator of claim 7 further comprises: a simulationparameter table that contains information that includes information forseveral patterns for functional stimulation exercise.
 10. The functionalelectrical stimulator of claim 7 wherein the program resident in thestimulator executes a stimulation pattern retrieved from the stimulationparameter table in accordance with thumbswitches or the Hall effectsensors coupled to the stimulator.
 11. The functional electricalstimulator of claim 10 wherein the program in the stimulator schedulesand executes stimulation pulses for channels, samples and processescontrol signal data and performs user notification via an LED.